{include file="public/meat" title="用户列表"/}
<div class="cx-fex-c">
    <div class="x11 pad-t15 pad-b10">
        <div class="cx-fex-c">
            <div class="xs6 xl12">
                <a href="{:url('index')}" class="button bg-blue">用户列表</a>
                {if $btn.add}
                <a href="{:url('add')}" class="button bg-blue">添加新用户</a>
                {/if}
                <a href="{:url('huishou')}" class="button bg-yellow">回收站管理</a>
            </div>
            <div class="xs6 xl12">
                <form class="layui-form" role="form" action="so" method="post">
                    <div class="cx-fex-r">
                        <label class="lab">搜索</label>
                        <input class="ipt" name="keyword" placeholder="请输入搜索内容" type="text" style="width: 200px;">
                        <button class="button f-l" type="submit"><i class="cx-icon cx-icon-sousuo"></i></button>
                    </div>
                </form>
            </div>
        </div>
    </div>
    <div class="x11">
        <form class="layui-form" role="form" action="" method="post">
            <table class="cx-teble cx-teble-bor-w cx-teble-bor cx-table-striped cx-table-hover cx-table-responsive-w">
                <thead>
                <tr>
                    <th class="{if !$btn.del}t-c{/if}">
                        <div class="checkbox">
                            <label>
                                {if $btn.del}<input id="all" class="inverted" type="checkbox" lay-ignore>{/if}
                                <span class="text">UID</span>
                            </label>
                        </div>
                    </th>
                    <th>会员名</th>
                    <th class="t-c" width="120">会员组</th>
                    <th>用户昵称</th>
                    <th>电子邮箱</th>
                    <th>时间</th>
                    <th>IP</th>
                    {if $btn.edit || $btn.del}<th class="t-c" width="120">编辑</th>{/if}
                    <th class="t-c" width="120">审核</th>
                </tr>
                </thead>
                <tbody>
                {volist name="list" id="cx"}
                <tr>
                    <td class="alltd table-line-height {if !$btn.del}t-c{/if}">
                        <div class="checkbox">
                            <label>
                                {if $btn.del}<input class="inverted" name="delid[{$cx.uid}]" type="checkbox" value="{$cx.uid}" lay-ignore>{/if}
                                <span class="text">{$cx.uid}</span>
                            </label>
                        </div>
                    </td>
                    <td>{$cx.username}</td>
                    <td class="t-c">{$cx.group_name}</td>
                    <td>{$cx.uniname}</td>
                    <td>{$cx.uemail}</td>
                    <td>注册：{$cx.uregtime}<br>访问：{$cx.ulogtime}</td>
                    <td>注册：{$cx.uregip}<br>访问：{$cx.ulogip}</td>
                    {if $btn.edit || $btn.del}
                    <td class="t-c">
                        {if $btn.edit}<a class="button button-S bg-blue mr-5" href="{:url('edit',array('uid'=>$cx['uid']))}" title="编辑【{$cx.username}】资料">编辑</a>{/if}
                        {if $btn.del}<a class="button button-S bg-red cx-click" data-id="{$cx['uid']}" data-href="{:url('del')}" data-type="deldata">删除</a>{/if}
                    </td>
                    {/if}
                    <td class="t-c">{if $btn.edit}{$cx.statuszh}{else}{$cx.statusurl}{/if}</td>
                </tr>
                {/volist}
                </tbody>
            </table>
            <div class="t-c pad-t20">
                {$list->render()}
            </div>
            <div class="t-c pad-t20">
                {if $btn.del}
                <button class="button button-S bg-yellow" data-href="{:url('edel')}" data-type="sort" lay-submit lay-filter="sd-btn">删除至回收站</button>
                <button class="button button-S bg-red" data-href="{:url('pdel')}" data-type="sort" lay-submit lay-filter="sd-btn">彻底删除</button>
                {/if}
            </div>
        </form>
    </div>
</div>
<div style="height: 20px; overflow: hidden"></div>
{include file="public/js" /}
<script>
    layui.config({
        base: '__ADMIN__/js/'
    }).use('app');
</script>
<script>
    $("#all").click(function () {
        $(this).closest("table").find("td.alltd input:checkbox").prop("checked",$(this).prop("checked"))
    })
</script>
{include file="public/footer" /}